import GridItem from '@/components/GridItem'
import React, { Component } from 'react'

class Hotcate extends Component {
  render() {
    return (
      <div className="home-hotcate-container">
        <div className="title">热门分类</div>
        {this.props.data.length > 0 ? (
          <GridItem
            onClick={id => {
              console.log(id, this.props.history)
            }}
            data={this.props.data}
          />
        ) : null}
      </div>
    )
  }
}

export default Hotcate
